package com.zh.media.domain.dto;

import com.zh.web.base.BaseDto;
import com.zh.web.enums.CrawlSource;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;

import java.time.LocalDateTime;

@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = true)
@Data
@ApiModel("文章爬虫参数实体")
public class ArticleCrawlDto extends BaseDto {
    @ApiModelProperty(value = "爬取起点url,从ls_crawl_source表中选择", example = "https://search.bilibili.com/article")
    private String startUrl = "https://search.bilibili.com/article";
    @ApiModelProperty(value = "关键词,从字段选取", example = "劳动法")
    private String keyword = "劳动法";
    @ApiModelProperty(value = "最大页码", example = "42")
    private Integer maxPage = 42;
    @ApiModelProperty(value = "排序参数", example = "order=pubdate")
    private String orderBy;
    @ApiModelProperty(value = "该时点至今时间范围内", example = "2024-01-01 00:00:00")
    private LocalDateTime startTime;
    @ApiModelProperty(value = "爬取来源", example = "100")
    private CrawlSource crawlSource;
    @ApiModelProperty("true:开启爬虫 false:关闭爬虫")
    private Boolean enable;
}
